package day76.ling.in.web.controller;

import day76.ling.in.entity.Emp;
import day76.ling.in.services.EmpServices;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/emp")
public class EmpController {
    @Autowired
    private EmpServices empServices;
    @GetMapping("/getAll")
    public List<Emp> getAll(){
        return empServices.getAll();
    }
}
